home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / comm / tlx_sq15.zip / PASSWORD.SLT < prev    next >
Text File  |  1990-10-12  |  1KB  |  37 lines

  1. //-----------------------------------------------------------
  2. // PASSWORD.SL? Send password.
  3. //
  4. // Please look at the comments through the whole file, and modify to
  5. // suit your needs, BEFORE you use it. Then recompile with CS PASSWORD.
  6.  
  7. // If you have suggestions for improving this script, please suggest
  8. // improvements to me via old-fashioned snail-mail to:
  9.  
  10. //   Inge Vabekk
  11. //   Hamangskogen 108
  12. //   N-1300 SANDVIKA
  13. //   NORWAY                   
  14. //-----------------------------------------------------------
  15.  
  16. str global[]="GLOBAL"
  17.    ,passw []="PASSW"
  18.    ;
  19.  
  20. //-----------------------------------------------------------
  21. // Script starts here.
  22. //-----------------------------------------------------------
  23.  
  24. main()
  25. {
  26. int i;
  27. str line[20];
  28.  
  29.   call (global,"R",passw,line);          // Get password.
  30.   i = strlen (line)-1;
  31.   if (subchr (line,i)<=' ')              // Delete any trailing CR.
  32.   setchr (line,i,0);
  33.   cputs (line);                          // Send it.
  34.   cputs ("^M");
  35. }
  36.  
  37.